package com.jt.assistant.utils;

/**
 * @ProjectName: JtAssistant
 * @Package: com.jt.assistant.utils
 * @ClassName: FastClickUtil
 * @Description: java类作用描述
 * @Author: zhuws
 * @CreateDate: 2020/5/23 下午3:24
 * @UpdateUser: 更新者
 * @UpdateDate: 2020/5/23 下午3:24
 * @UpdateRemark: 更新说明
 * @Version: 1.0
 */
public class FastClickUtil {

    private static final int MIN_CLICK_DELAY_TIME = 1000;
    private static long lastClickTime;

    public static boolean isFastClick() {
        boolean flag = true;
        long curClickTime = System.currentTimeMillis();
        if ((curClickTime - lastClickTime) >= MIN_CLICK_DELAY_TIME) {
            flag = false;
        }
        lastClickTime = curClickTime;
        return flag;
    }

}
